<?php

function pdfcreate($buffer) {

    require_once("dompdf/dompdf_config.inc.php");

    $dompdf = new DOMPDF();
    $dompdf->load_html($buffer);
    $dompdf->set_paper('letter', 'portrait');
    $dompdf->render();
    $dompdf->stream("Relatorio.pdf");
}

?>